﻿using MetroDataApi.Models;
using Newtonsoft.Json;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Net;
using System.Net.Http;
using System.Web.Http;

namespace MetroDataApi.Controllers.Management
{
    public class AutoSurveyStationsController : ApiController
    {
        // GET api/autosurveystations
        public string Get()
        {
            using (var db = new AutoSurveyDataDataContext())
            {
                var list = from s in db.stations
                           where s.type == "dist"
                           select s;
                return JsonConvert.SerializeObject(list.ToList());
            }
        }

    }
}
